package com.acme.domain.account;

public class SavingAccount extends AbstractAccount
{
	public SavingAccount(final double amount)
	{
		super(amount);
	}

	@Override
	public void deposit(final double amount)
	{
		balance += amount; 
	}
	
	@Override
	public void withdraw(final double amount)
	{
		if (amount < balance)
		{
			balance -= amount;
		}
		else
		{
			System.out.println("There is not enough " + 
					"money on your saving account");
		}
	}
}
